<?php

use think\migration\Migrator;
use think\migration\db\Column;

class CreateThirdLogin extends Migrator
{
    public function up()
    {
        $table = $this->table('third_login',['signed' => false,'comment'=>'第三方登录表']);
//        $table->addColumn('user_id','integer',['limit'=>10,'comment'=>'用户Id'])
//            ->addForeignKey('user_id', 'user', 'id', ['delete'=> 'CASCADE'])
//            ->addColumn('third_key','string',['limit'=>32,'comment'=>'第三方登录唯一标识'])
//            ->addColumn('create_time','integer',['limit'=>10,'comment'=>'创建时间'])
//            ->addColumn('update_time','integer',['limit'=>10,'comment'=>'更新时间'])
//            ->save();
    }

    public function down()
    {
        $this->dropTable('third_login');
    }

}
